
num = 100


def test_a():
    print(num)


def test_b():
    # 在函数中将 局部变量 变为 全局变量
    global num
    num = 200
    print(num)


test_a()
test_b()
print(num)

# range 语法
for x in range(5, 10):
    print(x)

# range 语法3(num1, num2, step)
for x in range(5, 10, 2):
    if x == 5:
        print("continue")
        continue
    print(x)


def hell(p1):
    """
    方法注释
    :param p1: 参数
    :return:
    """
    print(f"返回None类型{p1}")
    return None


if not hell(1):
    print("None在if中为false")

print(type(hell(1)))
